package com.kws.merchant.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.kws.merchant.domain.Merchant;
import com.kws.merchant.domain.po.*;
import com.kws.merchant.domain.vo.*;
import com.kws.system.api.domain.SysUser;
import org.springframework.web.multipart.MultipartFile;

import java.util.LinkedList;
import java.util.List;

/**
 * (Merchant)表服务接口
 *
 * @author yxy
 * @since 2024-11-01 09:43:21
 */
public interface MerchantService extends IService<Merchant> {

    boolean checkLoginCompany(Long userId);

    boolean createCompanyMessage(CreateCompanyMessageRq rq);

    String uploadCompanyFile(MultipartFile file);

    Merchant queryCompanyMessageByUserId(Long userId);

    /**
     * 商家入驻审核
     * @param checkVo
     * @return
     */
    boolean merchantCheck(CheckVo checkVo);

    /**
     * 商家入驻信息分页
     * @param merchantPagePo
     * @return
     */
    Page<Merchant> pageList(MerchantPagePo merchantPagePo);

    /**
     * 商家数据统计
     * @return
     */
    LinkedList<MerchantStatisticVo> statistics();

    Object getByUserId(Long userId);

    /**
     * 商家信息修改
     * @param merchant
     * @return
     */
    Object updateMerchant(Merchant merchant);

    /**
     * 商家收支管理-支付金额排行
     * @return
     */
    OrderRankMerchantVo merchantOverview(IncomePo incomePo);

    /**
     * 修改商品浏览记录
     * @return
     */
    boolean updateGoodsView(Long goodsViewId);

    Merchant detail();

    /**
     *
     * @param merchant
     * @return
     */
    Object addMerChant(Merchant merchant);

    /**
     * 商家个人信息详情
     * @param id
     * @return
     */
    Merchant detailById(Long id);

    /**
     * 商家项目统计
     * @return
     */
    ItemStatisticsVo itemStatistics(ItemStatisticsPo itemStatisticsPo);

    /**
     * 商家收支管理-实时概况
     * @param incomePo
     * @return
     */
    RealTimeVo realTimeOverview(IncomePo incomePo);

    /**
     * 商家收支管理-浏览看板
     * @param incomePo
     * @return
     */
    FlowTimeVo flowOverview(IncomePo incomePo);

    /**
     * 商家收支管理-整体看板
     * @param incomePo
     * @return
     */
    AllTineVo allOverview(IncomePo incomePo);

    /**
     * 微电网--销售额统计
     * @param microgridPo
     * @return
     */
    MicrogridVo microgridSale(MicrogridPo microgridPo);

    /**
     * 微电网--销售额分类
     * @param microgridPo
     * @return
     */
    List<MicrogridSale> microgridSaleType(MicrogridPo microgridPo);

    /**
     * 微电网--运维统计
     * @param microgridOrderPo
     * @return
     */
    MicrogridVo microgridWorkOrder(MicrogridOrderPo microgridOrderPo);

    /**
     * 商家用户下拉
     * @return
     */
    List<SysUser> merchantUserList();

    /**
     * 微电网--订单总览
     * @param microgridPo
     * @return
     */
    List<OrderOverviewVo> orderOverview(MicrogridPo microgridPo);
}
